bitkeeper revision 1.1385.1.3 (426f6b05kK8EBkiTLCXBeJZCPG2ZgQ)
authorkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Wed, 27 Apr 2005 10:35:49 +0000 (10:35 +0000)
committerkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Wed, 27 Apr 2005 10:35:49 +0000 (10:35 +0000)
Cset exclude: bren@br260.wolfson.cam.ac.uk|ChangeSet|20050426221254|30123

tools/libxc/xc_domain.c
xen/common/dom0_ops.c
xen/common/dom_mem_ops.c

index 85bd4811805d36027c89582d0fef6c36d3a66cf9..1d8815a8a67c53e8b878c56709418bc4a92ef824 100644 (file)
@@ -35,7 +35,7 @@ int xc_domain_create(int xc_handle,
         goto fail;
 
     if ( (err = do_dom_mem_op(xc_handle, MEMOP_increase_reservation,
-                              NULL, mem_kb/4 + 1, 0, *pdomid)) != (mem_kb/4) )
+                              NULL, mem_kb/4, 0, *pdomid)) != (mem_kb/4) )
     {
         if ( err > 0 )
             errno = ENOMEM;
index 0d3966f994a2eb9f71eee65a9b52a2fbd58f4473..da454a479a1723130e5352c1cde9a650779bf129 100644 (file)
@@ -411,8 +411,7 @@ long do_dom0_op(dom0_op_t *u_dom0_op)
         d = find_domain_by_id(op->u.setdomainmaxmem.domain);
         if ( d != NULL )
         {
-            d->max_pages = (op->u.setdomainmaxmem.max_memkb +
-                            ((PAGE_SIZE-1)>>10)) >> (PAGE_SHIFT-10);
+            d->max_pages = op->u.setdomainmaxmem.max_memkb >> (PAGE_SHIFT-10);
             put_domain(d);
             ret = 0;
         }
index 9b5d50cfc21af74f77940562dc5bb3c8aaa23969..698f6ee835c5aa388156a95b0b1cad920a557580 100644 (file)
@@ -61,9 +61,6 @@ alloc_dom_mem(struct domain *d,
             return i;
         }
 
-        /* Initialise the machine-to-phys mapping for this page. */
-        set_machinetophys(page_to_pfn(page), d->tot_pages - 1);
-
         /* Inform the domain of the new page's machine address. */ 
         if ( (extent_list != NULL) && 
              (__put_user(page_to_pfn(page), &extent_list[i]) != 0) )